package com.hdoit.ares.logical.acc.model;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;

import org.apache.ibatis.type.Alias;

import com.tennetcn.common.message.ModelBase;
/**
 * @author      yujinhui
 * @email       
 * @createtime  2017年11月29日 12:01:13
 * @comment
 */
@Alias("customerDemo")
@Entity
@Table(name="acc_customer_demo")
public class CustomerDemo extends ModelBase implements Comparable<CustomerDemo>{
    //主键
    @Id
    @Column(name="id")
    private String id;

    //姓名
    @Column(name="username")
    private String username;

    //介绍人id
    @Column(name="refereeId")
    private String refereeId;

    //注册时间
    @Column(name="registDate")
    private Date registDate;

    //客户级别
    @Column(name="level")
    private String level;

    //删除标识
    @Column(name="deleteMark")
    private String deleteMark;
    
    //用户标识符
    @Column(name="userIdentity")
    private int userIdentity;

    //推荐人标识符
    @Column(name="refereeIdentity")
    private int refereeIdentity;
    
    //利润分配顺序位置
    @Transient
    private Integer sord;
    
    //利润分配总百分比
    @Transient
    private Double tempPercentege;
    
    //利润分配百分比
    @Transient
    private Double promote;
    
    //利润分配百分比
    @Transient
    private Double firstShare;
    
    //利润分配百分比
    @Transient
    private Double secondShare;
    
    //利润分配百分比
    @Transient
    private Double server;
    
    //利润分配百分比
    @Transient
    private Double hatch;
    
    public int getUserIdentity() {
		return userIdentity;
	}
	public void setUserIdentity(int userIdentity) {
		this.userIdentity = userIdentity;
	}
	public int getRefereeIdentity() {
		return refereeIdentity;
	}
	public void setRefereeIdentity(int refereeIdentity) {
		this.refereeIdentity = refereeIdentity;
	}
	public Double getPromote() {
		return promote;
	}
	public void setPromote(Double promote) {
		this.promote = promote;
	}
	public Double getFirstShare() {
		return firstShare;
	}
	public void setFirstShare(Double firstShare) {
		this.firstShare = firstShare;
	}
	public Double getSecondShare() {
		return secondShare;
	}
	public void setSecondShare(Double secondShare) {
		this.secondShare = secondShare;
	}
	public Double getServer() {
		return server;
	}
	public void setServer(Double server) {
		this.server = server;
	}
	public Double getHatch() {
		return hatch;
	}
	public void setHatch(Double hatch) {
		this.hatch = hatch;
	}
	public String getId(){
        return this.id;
    }
    public void setId(String id){
         this.id=id;
    }

    public String getUsername(){
        return this.username;
    }
    public void setUsername(String username){
         this.username=username;
    }

    public String getRefereeId(){
        return this.refereeId;
    }
    public void setRefereeId(String refereeId){
         this.refereeId=refereeId;
    }

    public Date getRegistDate(){
        return this.registDate;
    }
    public void setRegistDate(Date registDate){
         this.registDate=registDate;
    }

    public String getLevel(){
        return this.level;
    }
    public void setLevel(String level){
         this.level=level;
    }

    public String getDeleteMark(){
        return this.deleteMark;
    }
    public void setDeleteMark(String deleteMark){
         this.deleteMark=deleteMark;
    }
	public Integer getSord() {
		return sord;
	}
	public void setSord(Integer sord) {
		this.sord = sord;
	}
	public Double getTempPercentege() {
		return tempPercentege;
	}
	public void setTempPercentege(Double tempPercentege) {
		this.tempPercentege = tempPercentege;
	}
	@Override
	public int compareTo(CustomerDemo o) {
		 return this.sord - o.getSord();
	}
    
	public CustomerDemo(){
		this.promote = 0.0;
		this.firstShare = 0.0;
		this.secondShare = 0.0;
		this.server = 0.0;
		this.hatch = 0.0;
		this.tempPercentege = 0.0;
	}
}
